package com.ruoyi.yipaiju.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.yipaiju.mapper.DiscountHouseBookingorderMapper;
import com.ruoyi.yipaiju.domain.DiscountHouseBookingorder;
import com.ruoyi.yipaiju.service.IDiscountHouseBookingorderService;

/**
 * fo_discount_house_bookingorderService业务层处理
 * 
 * @author liuwp
 * @date 2023-03-01
 */
@Service
public class DiscountHouseBookingorderServiceImpl implements IDiscountHouseBookingorderService 
{
    @Autowired
    private DiscountHouseBookingorderMapper discountHouseBookingorderMapper;

    /**
     * 查询fo_discount_house_bookingorder
     * 
     * @param id fo_discount_house_bookingorder主键
     * @return fo_discount_house_bookingorder
     */
    @Override
    public DiscountHouseBookingorder selectDiscountHouseBookingorderById(Long id)
    {
        return discountHouseBookingorderMapper.selectDiscountHouseBookingorderById(id);
    }

    /**
     * 查询fo_discount_house_bookingorder列表
     * 
     * @param discountHouseBookingorder fo_discount_house_bookingorder
     * @return fo_discount_house_bookingorder
     */
    @Override
    public List<DiscountHouseBookingorder> selectDiscountHouseBookingorderList(DiscountHouseBookingorder discountHouseBookingorder)
    {
        return discountHouseBookingorderMapper.selectDiscountHouseBookingorderList(discountHouseBookingorder);
    }
    @Override
    public List<DiscountHouseBookingorder> selectDiscountHouseBookingorderList1(DiscountHouseBookingorder discountHouseBookingorder)
    {
        return discountHouseBookingorderMapper.selectDiscountHouseBookingorderList1(discountHouseBookingorder);
    }

    /**
     * 根据业务主键查询一条记录：fo_discount_house_bookingorder
     *
     * @param discountHouseBookingorder fo_discount_house_bookingorder
     * @return fo_discount_house_bookingorder
     */
    @Override
    public DiscountHouseBookingorder selectOneDiscountHouseBookingorder(DiscountHouseBookingorder discountHouseBookingorder)
    {
        return discountHouseBookingorderMapper.selectOneDiscountHouseBookingorder(discountHouseBookingorder);
    }

    /**
     * 新增fo_discount_house_bookingorder
     * 
     * @param discountHouseBookingorder fo_discount_house_bookingorder
     * @return 结果
     */
    @Override
    public int insertDiscountHouseBookingorder(DiscountHouseBookingorder discountHouseBookingorder)
    {
        discountHouseBookingorder.setCreateTime(DateUtils.getNowDate());
        return discountHouseBookingorderMapper.insertDiscountHouseBookingorder(discountHouseBookingorder);
    }

    /**
     * 修改fo_discount_house_bookingorder
     * 
     * @param discountHouseBookingorder fo_discount_house_bookingorder
     * @return 结果
     */
    @Override
    public int updateDiscountHouseBookingorder(DiscountHouseBookingorder discountHouseBookingorder)
    {
        discountHouseBookingorder.setUpdateTime(DateUtils.getNowDate());
        return discountHouseBookingorderMapper.updateDiscountHouseBookingorder(discountHouseBookingorder);
    }

    @Override
    public int updateDiscountHouseBookingorderCondition(DiscountHouseBookingorder discountHouseBookingorder, DiscountHouseBookingorder discountHouseBookingorderCondition)
    {
                discountHouseBookingorder.setUpdateTime(DateUtils.getNowDate());
        return discountHouseBookingorderMapper.updateDiscountHouseBookingorderCondition(discountHouseBookingorder, discountHouseBookingorderCondition);
    }

    /**
     * 批量删除fo_discount_house_bookingorder
     * 
     * @param ids 需要删除的fo_discount_house_bookingorder主键
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseBookingorderByIds(Long[] ids)
    {
        return discountHouseBookingorderMapper.deleteDiscountHouseBookingorderByIds(ids);
    }

    /**
     * 删除fo_discount_house_bookingorder信息
     * 
     * @param id fo_discount_house_bookingorder主键
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseBookingorderById(Long id)
    {
        return discountHouseBookingorderMapper.deleteDiscountHouseBookingorderById(id);
    }

    /**
     * 条件删除fo_discount_house_bookingorder
     *
     * @param discountHouseBookingorder fo_discount_house_bookingorder
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseBookingorderByCondition(DiscountHouseBookingorder discountHouseBookingorder)
    {
        return discountHouseBookingorderMapper.deleteDiscountHouseBookingorderByCondition(discountHouseBookingorder);
    }

}
